#include "stdafx.h"
#include "Aspector.h"

void CAspector::ExecuteBeforeAdvices(CStackFrameDescriptor& descriptor)
{
	std::list<IMethodInterceptorAdvice*>::iterator pIt = this->aspects.begin();
	while ( pIt!=this->aspects.end() )
	{
		(*pIt)->Before();
		pIt++;
	}
}

int CAspector::ExecuteAfterAdvices(CStackFrameDescriptor& descriptor,int returnValue)
{
	std::list<IMethodInterceptorAdvice*>::iterator pIt = this->aspects.begin();
	while ( pIt!=this->aspects.end() )
	{
		(*pIt)->After();
		pIt++;
	}
	return returnValue;
}

void CAspector::ExecuteThrowAdvices(CStackFrameDescriptor& descriptor)
{
}

